<template>
  <div class="supplier_display_header">
    <img src="@/assets/images/supplierDisplayCenter/biao.svg"/>
    <span>{{title}}</span>
    <span v-show="showMore" @click="toList">查看更多</span>
    <slot name="action"></slot>
  </div>
</template>

<script>
export default {
  name: "SupplierDisplayHeader",
  props:{
    title:'',
    showMore:{
      type:Boolean,
      default:true
    }
  },
  methods: {
    toList() {
      this.$emit('more')
    }
  }
}
</script>

<style scoped lang="scss">
$colorPrimary: #3370FF;
.supplier_display_header {
  font-family: PingFangSC-Semibold, sans-serif;
  font-size: 18px;
  line-height: 22px;
  color: #1E2225;
  
  img {
    width: 22px;
    height: 22px;
  }

  span:last-child {
    font-family: PingFangSC-Regular, sans-serif;
    font-size: 14px;
    float: right;
    cursor: pointer;
    color: #646464;

    &:hover {
      color: $colorPrimary;
    }
  }
}
</style>
